Primitive Class Color

Represents an RGBA or RGB color.

Components are specified in bytes. All values are clamped to the range [0, 255].

Members

r (int) Red component.
g (int) Green component.
b (int) Blue component.
a (int) Alpha component (0 = invisible, 255 = opaque).

Functions

Color(R, G, B)
__tostring(color)


Members

r
(int) Red component.
g
(int) Green component.
b
(int) Blue component.
a
(int) Alpha component (0 = invisible, 255 = opaque).

Functions

Color(R, G, B)

Parameters:

  • R int red component
  • G int green component
  • B int blue component

Returns:

    Color A new Color object.
__tostring(color)

Parameters:

  • color Color This color.

Returns:

    string A string representing the r, g, b, and a values of the color.
generated by TEN-LDoc (a fork of LDoc 1.4.6)